<template>
  <div class="imgitem">
    <div class="itembox"><img class="imgimg" v-lazy="elm.path" alt="" /></div>
    <div class="imgname" @click="full">{{ elm.name }}</div>
  </div>
</template>

<script>
export default {
  name: "imgcard",
  props: {
    elm: Object,
    full: Function,
  },
};
</script>

<style>
.imgitem {
  background-color: #fff;
  width: 15.47%;
  min-width: 240px;
  margin-left: 10px;
  margin-bottom: 40px;
  display: inline-block;
  box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.3);
}
@media screen and (max-width: 500px) {
  .imgitem {
    width: 100%;
    margin-left: 0;
  }
}
.itembox {
  width: 100%;
  min-height: 348.88px;
  display: flex;
  align-items: center;
  background-color: #0000000f;
}
.imgimg {
  width: 100%;
}
.imgname {
  color: #333;
  font-size: 16px;
  text-align: center;
  flex-wrap: 600;
  cursor: pointer;
  transition: all 0.4s;
  padding: 12px 0;
}
.imgname:hover {
  color: #c5947e;
}
</style>